

from celery import Celery

# include =[] 元素是任务
app = Celery('MyCelery')

# 加载配置文件
app.config_from_object('celery_tas.celeryconfig')
# 自动发现任务
app.autodiscover_tasks(['celery_tas.Celery.celery.sms_code'])
